<?php

declare (strict_types=1);
/*
 * This file is part of Leonsw.
 *
 * @link     https://leonsw.com
 * @document https://docs.leonsw.com
 * @contact  leonsw.com@gmail.com
 * @license  https://leonsw.com/LICENSE
 */
namespace App\Models\MainDB\BlindBox;

use Illuminate\Database\Eloquent\Model;
/**
 * @property int $id 
 * @property string $name 
 * @property string $type 
 * @property int $round 
 * @property int $count 
 * @property int $input 
 * @property int $output
 * @property int $prize_count
 * @property \Carbon\Carbon $created_at 
 * @property \Carbon\Carbon $updated_at 
 */
class PoolSetting extends Model
{
    public const NOVICE_TYPE = 'novice';

    public const DEFAULT_TYPE = 'default';

    public const PROBABILITY_TYPE = 'probability';

    public const BONUS_BIGGEST_TYPE = 'bonusBiggest';

    public const BONUS_LEAST_TYPE = 'bonusLeast';

    public const SCORE_TYPE = 'score';

    // 怒气奖池
    public const SYSTEM_CUSTOM_POOLS = [self::BONUS_BIGGEST_TYPE, self::BONUS_LEAST_TYPE, self::SCORE_TYPE];

    protected $table = 'ln_blind_box_pool_setting';
    //protected $fillable = [];
    protected $guarded = [];
    protected $casts = ['id' => 'int', 'type' => 'string', 'template_type' => 'string', 'lucky_type' => 'string', 'coin_rate' => 'integer', 'input' => 'integer', 'output' => 'integer', 'coin' => 'integer', 'temp_coin' => 'integer', 'total_coin' => 'integer', 'open_coin' => 'integer', 'open_interval_second' => 'integer', 'sort' => 'integer', 'is_dynamic' => 'integer', 'is_open' => 'integer', 'last_draw_at' => 'datetime', 'created_at' => 'datetime', 'updated_at' => 'datetime'];

    public function getDateFormat()
    {
        return 'Y-m-d H:i:s.u';
    }
}